<?php include _include(ADMIN_PATH.'view/htm/header.inc.htm'); ?>

<?php include _include(HAYA_FILE_HTML.'common/tab.htm'); ?>

<div class="row mt-3">
	<div class="col-sm-12">
		
		<div class="card">
			<div class="card-body">
				<form action="<?php echo url('attachlite-setting');?>" method="post" id="formcreate">
					<h4 class="card-title">附件管理设置</h4>
					
					<hr class="mx-0 my-3 mb-4" />
					
					<div class="form-group row mb-3">
						<label class="col-sm-2 form-control-label text-md-right pr-0">
							附件数量：
						</label>
						<div class="col-sm-10">
							<div>
								<?php echo $attach_count; ?> 个
							</div>
							
							<div class="figure-caption mt-2">
								已有附件数量统计。
							</div>
						</div>
					</div>
					
					<div class="form-group row mb-3">
						<label class="col-sm-2 form-control-label text-md-right pr-0" for="show_pic">详情显示图片：</label>
						<div class="col-sm-10">
							<div class="custom-redio" id="show_pic">
								<?php if (isset($config['show_pic']) && $config['show_pic'] == 1) { ?>
									<label class="custom-input custom-radio mr-3">
										<input type="radio" name="show_pic" value="1" checked="checked"> 显示
									</label>
									<label class="custom-input custom-radio mr-3">
										<input type="radio" name="show_pic" value="0"> 关闭
									</label>
								<?php } else { ?>
									<label class="custom-input custom-radio mr-3">
										<input type="radio" name="show_pic" value="1"> 显示
									</label>
									<label class="custom-input custom-radio mr-3">
										<input type="radio" name="show_pic" value="0" checked="checked"> 关闭
									</label>
								<?php } ?>
							</div>		
							<div class="figure-caption mt-2">
								在详情页显示图片附件的预览。
							</div>
						</div>
					</div>
					
					<div class="form-group row mb-3">
						<label class="col-sm-2 form-control-label text-md-right pr-0" for="list_type">列表风格：</label>
						<div class="col-sm-10">
							<div class="custom-redio" id="list_type">
								<?php if (isset($config['list_type']) && $config['list_type'] == 1) { ?>
									<label class="custom-input custom-radio mr-3">
										<input type="radio" name="list_type" value="0"> 简洁
									</label>
									<label class="custom-input custom-radio mr-3">
										<input type="radio" name="list_type" value="1" checked="checked"> 详细
									</label>
								<?php } else { ?>
									<label class="custom-input custom-radio mr-3">
										<input type="radio" name="list_type" value="0" checked="checked"> 简洁
									</label>
									<label class="custom-input custom-radio mr-3">
										<input type="radio" name="list_type" value="1"> 详细
									</label>
								<?php } ?>
							</div>		
							<div class="figure-caption mt-2">
								附件列表显示情况，可以根据自己情况选择。
							</div>
						</div>
					</div>
					
					<div class="form-group row mb-3">
						<label class="col-sm-2 form-control-label"></label>
						<div class="col-sm-2">
							<button type="submit" class="btn btn-primary btn-block mb-3 mr-0" id="submit"><?php echo lang('save');?></button>
						</div>
						<div class="col-sm-2">
							<a role="button" class="btn btn-secondary btn-block mb-3" href="javascript:history.back();"><?php echo lang('back');?></a>
						</div>
					</div>
					
				</form>
			</div>
		</div>
	</div>
</div>

<?php include _include(HAYA_FILE_HTML.'common/footer.htm'); ?>

